import {Table, Column, Model, ForeignKey,BelongsTo} from "sequelize-typescript";
import {Dynamic} from "./dynamic";

@Table({
    tableName: 'like'
})
export class Like extends Model<Like> {
    // @Column
    // dy_id!: string // 动态id

    @Column
    user_id!: string // 点赞用户的id

    @ForeignKey(() => Dynamic) @Column dy_id!:number
    @BelongsTo(()=>Dynamic) likes!: Dynamic
}
